3.56 \(\int \cosh ((a+b x)^2) \, dx\)

Optimal. Leaf size=37 \[ \frac{\sqrt{\pi } \text{Erf}(a+b x)}{4 b}+\frac{\sqrt{\pi } \text{Erfi}(a+b x)}{4 b} \]

[Out]

(Sqrt[Pi]*Erf[a + b*x])/(4*b) + (Sqrt[Pi]*Erfi[a + b*x])/(4*b)

________________________________________________________________________________________

Rubi [A]  time = 0.017185, antiderivative size = 37, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 4, integrand size = 8, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.5, Rules used = {5311, 5299, 2204, 2205} \[ \frac{\sqrt{\pi } \text{Erf}(a+b x)}{4 b}+\frac{\sqrt{\pi } \text{Erfi}(a+b x)}{4 b} \]

Antiderivative was successfully verified.

[In]

Int[Cosh[(a + b*x)^2],x]

[Out]

(Sqrt[Pi]*Erf[a + b*x])/(4*b) + (Sqrt[Pi]*Erfi[a + b*x])/(4*b)

Rule 5311

Int[((a_.) + Cosh[(c_.) + (d_.)*(u_)^(n_)]*(b_.))^(p_.), x_Symbol] :> Dist[1/Coefficient[u, x, 1], Subst[Int[(
a + b*Cosh[c + d*x^n])^p, x], x, u], x] /; FreeQ[{a, b, c, d, n}, x] && IntegerQ[p] && LinearQ[u, x] && NeQ[u,
 x]

Rule 5299

Int[Cosh[(c_.) + (d_.)*(x_)^(n_)], x_Symbol] :> Dist[1/2, Int[E^(c + d*x^n), x], x] + Dist[1/2, Int[E^(-c - d*
x^n), x], x] /; FreeQ[{c, d}, x] && IGtQ[n, 1]

Rule 2204

Int[(F_)^((a_.) + (b_.)*((c_.) + (d_.)*(x_))^2), x_Symbol] :> Simp[(F^a*Sqrt[Pi]*Erfi[(c + d*x)*Rt[b*Log[F], 2
]])/(2*d*Rt[b*Log[F], 2]), x] /; FreeQ[{F, a, b, c, d}, x] && PosQ[b]

Rule 2205

Int[(F_)^((a_.) + (b_.)*((c_.) + (d_.)*(x_))^2), x_Symbol] :> Simp[(F^a*Sqrt[Pi]*Erf[(c + d*x)*Rt[-(b*Log[F]),
 2]])/(2*d*Rt[-(b*Log[F]), 2]), x] /; FreeQ[{F, a, b, c, d}, x] && NegQ[b]

Rubi steps

\begin{align*} \int \cosh \left ((a+b x)^2\right ) \, dx &=\frac{\operatorname{Subst}\left (\int \cosh \left (x^2\right ) \, dx,x,a+b x\right )}{b}\\ &=\frac{\operatorname{Subst}\left (\int e^{-x^2} \, dx,x,a+b x\right )}{2 b}+\frac{\operatorname{Subst}\left (\int e^{x^2} \, dx,x,a+b x\right )}{2 b}\\ &=\frac{\sqrt{\pi } \text{erf}(a+b x)}{4 b}+\frac{\sqrt{\pi } \text{erfi}(a+b x)}{4 b}\\ \end{align*}

Mathematica [A]  time = 0.0037309, size = 25, normalized size = 0.68 \[ \frac{\sqrt{\pi } (\text{Erf}(a+b x)+\text{Erfi}(a+b x))}{4 b} \]

Antiderivative was successfully verified.

[In]

Integrate[Cosh[(a + b*x)^2],x]

[Out]

(Sqrt[Pi]*(Erf[a + b*x] + Erfi[a + b*x]))/(4*b)

________________________________________________________________________________________

Maple [C]  time = 0.031, size = 36, normalized size = 1. \begin{align*}{\frac{{\it Erf} \left ( bx+a \right ) \sqrt{\pi }}{4\,b}}-{\frac{{\frac{i}{4}}\sqrt{\pi }{\it Erf} \left ( ibx+ia \right ) }{b}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cosh((b*x+a)^2),x)

[Out]

1/4*erf(b*x+a)*Pi^(1/2)/b-1/4*I*Pi^(1/2)/b*erf(I*b*x+I*a)

________________________________________________________________________________________

Maxima [B]  time = 1.60752, size = 698, normalized size = 18.86 \begin{align*} \text{result too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cosh((b*x+a)^2),x, algorithm="maxima")

[Out]

1/2*((sqrt(pi)*(b^2*x + a*b)*a*b*(erf(sqrt(-(b^2*x + a*b)^2/b^2)) - 1)/((b^2)^(3/2)*sqrt(-(b^2*x + a*b)^2/b^2)
) - b^2*e^((b^2*x + a*b)^2/b^2)/(b^2)^(3/2))*a/sqrt(b^2) - (sqrt(pi)*(b^2*x + a*b)*a*b*(erf(sqrt((b^2*x + a*b)
^2/b^2)) - 1)/((-b^2)^(3/2)*sqrt((b^2*x + a*b)^2/b^2)) + b^2*e^(-(b^2*x + a*b)^2/b^2)/(-b^2)^(3/2))*a/sqrt(-b^
2) - (sqrt(pi)*(b^2*x + a*b)*a^2*b^2*(erf(sqrt((b^2*x + a*b)^2/b^2)) - 1)/((-b^2)^(5/2)*sqrt((b^2*x + a*b)^2/b
^2)) + 2*a*b^3*e^(-(b^2*x + a*b)^2/b^2)/(-b^2)^(5/2) - (b^2*x + a*b)^3*gamma(3/2, (b^2*x + a*b)^2/b^2)/((-b^2)
^(5/2)*((b^2*x + a*b)^2/b^2)^(3/2)))*b/sqrt(-b^2) - (sqrt(pi)*(b^2*x + a*b)*a^2*b^2*(erf(sqrt(-(b^2*x + a*b)^2
/b^2)) - 1)/((b^2)^(5/2)*sqrt(-(b^2*x + a*b)^2/b^2)) - 2*a*b^3*e^((b^2*x + a*b)^2/b^2)/(b^2)^(5/2) - (b^2*x +
a*b)^3*gamma(3/2, -(b^2*x + a*b)^2/b^2)/((b^2)^(5/2)*(-(b^2*x + a*b)^2/b^2)^(3/2)))*b/sqrt(b^2))*b + x*cosh((b
*x + a)^2)

________________________________________________________________________________________

Fricas [A]  time = 1.72179, size = 143, normalized size = 3.86 \begin{align*} \frac{\sqrt{\pi } \sqrt{b^{2}} \operatorname{erf}\left (\frac{\sqrt{b^{2}}{\left (b x + a\right )}}{b}\right ) + \sqrt{\pi } \sqrt{b^{2}} \operatorname{erfi}\left (\frac{\sqrt{b^{2}}{\left (b x + a\right )}}{b}\right )}{4 \, b^{2}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cosh((b*x+a)^2),x, algorithm="fricas")

[Out]

1/4*(sqrt(pi)*sqrt(b^2)*erf(sqrt(b^2)*(b*x + a)/b) + sqrt(pi)*sqrt(b^2)*erfi(sqrt(b^2)*(b*x + a)/b))/b^2

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \cosh{\left (\left (a + b x\right )^{2} \right )}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cosh((b*x+a)**2),x)

[Out]

Integral(cosh((a + b*x)**2), x)

________________________________________________________________________________________

Giac [C]  time = 1.21778, size = 53, normalized size = 1.43 \begin{align*} -\frac{i \, \sqrt{\pi } \operatorname{erf}\left (i \, b{\left (x + \frac{a}{b}\right )}\right )}{4 \, b} - \frac{\sqrt{\pi } \operatorname{erf}\left (-b{\left (x + \frac{a}{b}\right )}\right )}{4 \, b} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cosh((b*x+a)^2),x, algorithm="giac")

[Out]

-1/4*I*sqrt(pi)*erf(I*b*(x + a/b))/b - 1/4*sqrt(pi)*erf(-b*(x + a/b))/b